version: "3"

services:
  chatwizweb_node:
    # image: chatwiz_web
    container_name: chatwizweb_node
    build:
      context: .
      dockerfile: Dockerfile
    command:
      [
        "serve", "build"
      ]
    ports:
      - 3000:3000
    restart: always
    volumes:
      - ./src:/usr/src/app/src
      - ./public:/usr/src/app/public

  chatwizweb_nginx:
    # image: chatwiz_web_nginx
    container_name: chatwizweb_nginx
    build:
      context: ./nginx
      dockerfile: ./Dockerfile
    ports:
      - 80:80
      - 443:443
    depends_on:
      - chatwizweb_node
    restart: always
